#pragma once
#include "Control.h"
#include <vector>

namespace cxgui
{
using namespace std;

class ContainerControl : public Control
{
public:
	void Update() override;	
	virtual void DrawControls();
	void Draw() override;
	virtual void AddControl(shared_ptr<Control> control);
	size_t GetControlsCount() const;
	void RemoveControl(size_t index);
	virtual ~ContainerControl();		

	virtual bool IsLayoutDirty() const;

protected:
	virtual void OnControlCollectionChanged();
	vector<shared_ptr<Control>> _controls;	
};
}